package com.wkbb.common.enums;

/**
 * @author luowenyan
 * 进出(0 进 1出)
 */
public enum DoorEntranceTypeEnum {
    /**
     * 进
     */
    IN(0,"进"),

    /**
     * 出
     */
    OUT(1,"出");

    private DoorEntranceTypeEnum(Integer value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    private Integer value;

    private String desc;

    public Integer getValue() {
        return this.value;
    }

    public void setValue(Integer value) {
        this.value = value;
    }

    public String getDesc() {
        return this.desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public static String getDesc(Integer value) {
        for (DoorEntranceTypeEnum entranceType : DoorEntranceTypeEnum.values()) {
            if (entranceType.getValue().intValue()==value) {
                return entranceType.getDesc();
            }
        }
        return null;
    }
}
